import javafx.scene.canvas.GraphicsContext;
import javafx.scene.image.Image;

/**
 * 井
 */
public class Well extends Sprite{
    public Well(Image image, double x, double y, double width, double height) {
        super(image, x, y, width, height);

    }

    @Override
    public void pain(GraphicsContext graphicsContext) {
        super.pain(graphicsContext);
        if (MarioBros.Bj){
            x-= MarioBros.SuDu;
        }
        if (x<-20){
            GameScene.list.remove(this);
        }
    }

}
